<?php
namespace app\handler\wechat\ai;


use EasyWeChat\Kernel\Contracts\EventHandlerInterface;
use EasyWeChat\Kernel\Messages\Text;

class SubscribeMessageHandler implements  EventHandlerInterface
{

    /**
     * @param $message
     * @return Text
     */
    public function handle($message = null)
    {
        $subscribe = $message['Event'] ?? '';

        if ($subscribe == 'subscribe') {
            return new Text("Hi~我是智能竹虫，很高兴认识你\n你可以上传人脸图，有惊喜哦\n你还可以打字形式跟我聊天的\n更可以说国语翻译成粤语文字");
        }

        return null;
    }
}